'use strict';

const Controller = require('egg/index').Controller;

class MessageController extends Controller {
  /**
   * 批量删除
   */
  async batchDelete() {
    this.ctx.validate({
      list: {
        type: 'array',
        itemType: 'string',
      },
    });
    const data = await this.ctx.service.message.batchDelete(this.ctx.w_body().list);
    this.ctx.sendSuccess(data);
  }
}

module.exports = MessageController;
